<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
<hibernate-mapping>
    <class name="cn.firstsoft.modules.message.domain.MessagesEmailout" table="messages_emailout">
        <id name="id" type="integer">                                         
            <column name="id" />
            <generator class="native" >
				<param name="sequence">MESSAGES_EMAILOUT_ID_SEQ</param>
            </generator>            
        </id>
        <many-to-one name="fromUserId" class="org.springside.modules.security.domain.User" fetch="select" lazy="false">
            <column name="from_userid" />
        </many-to-one>
         <many-to-one name="toUserId" class="org.springside.modules.security.domain.User" fetch="select" lazy="false">
            <column name="to_userid" />
        </many-to-one>
        <property name="toEmail" type="string">
            <column name="to_email" length="50" />
        </property>
        <property name="toUserName" type="string">
            <column name="to_username" length="50" />
        </property>
         <property name="fromUserName" type="string">
            <column name="from_username" length="50" />
        </property>
        <property name="content" type="string">
            <column name="content" length="500" />
        </property>
        <property name="issend" type="integer">
            <column name="issend" />
        </property>
         <property name="createdate" type="timestamp">
            <column name="createdatetime" length="23" />
        </property>
        <property name="senddate" type="timestamp">
            <column name="senddatetime" length="23" />
        </property>
        <property name="sourceId" type="integer">
            <column name="source_id" />
        </property>
        <property name="type" type="integer">
            <column name="type" />
        </property>
    </class>
</hibernate-mapping>
